#include "stdafx.h"
#include "stdres.h"
#include "stdwin.h"
#include "app.h"
#include "win.h"
#include "gfx.h"

int Run(void)
{
 if(CreateMainWindow() == FALSE) return -1;
 return MessagePump(RenderFrame);
}

WINMAIN_HANDLER(basead, cmdline, cmdshow)
{
 SetInstance(basead);
 CoInitializeEx(0, COINIT_MULTITHREADED);
 int retval = Run();
 CoUninitialize();
 SetInstance(NULL);
 return retval;
}